package com.example.test.service.impl;


import com.example.test.entity.Role;
import com.example.test.mapper.RoleMapper;
import com.example.test.service.RoleService;
import com.example.test.util.MyBatisUtil;
import org.springframework.stereotype.Service;

import java.io.IOException;
import java.util.List;

@Service
public class RoleServiceImpl implements RoleService {

    @Override
    public Object getRoleInfo() throws IOException {
        MyBatisUtil myBatisUtil = new MyBatisUtil();
        RoleMapper roleMapper = myBatisUtil.roleMapperLoad();
        List<Role> all = roleMapper.findAll();
        return all;
    }
}
